package org.dromara.blog.domain.vo;

import org.dromara.blog.domain.BlogComment;
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
import cn.idev.excel.annotation.ExcelProperty;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;



/**
 * 博客评论视图对象 blog_comment
 *
 * @author LSY
 * @date 2025-11-13
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = BlogComment.class)
public class BlogCommentVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 评论ID
     */
    @ExcelProperty(value = "评论ID")
    private Long commentId;

    /**
     * 文章ID
     */
    @ExcelProperty(value = "文章ID")
    private Long articleId;

    /**
     * 父评论ID（0为顶级）
     */
    @ExcelProperty(value = "父评论ID", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "0=为顶级")
    private Long parentId;

    /**
     * 祖级ID链
     */
    @ExcelProperty(value = "祖级ID链")
    private String ancestors;

    /**
     * 评论内容
     */
    @ExcelProperty(value = "评论内容")
    private String content;

    /**
     * 访客昵称
     */
    @ExcelProperty(value = "访客昵称")
    private String visitorName;

    /**
     * 访客邮箱
     */
    @ExcelProperty(value = "访客邮箱")
    private String visitorEmail;

    /**
     * 访客IP
     */
    @ExcelProperty(value = "访客IP")
    private String visitorIp;

    /**
     * 点赞数
     */
    @ExcelProperty(value = "点赞数")
    private Long likeCount;

    /**
     * 回复数
     */
    @ExcelProperty(value = "回复数")
    private Long replyCount;

    /**
     * 是否已审核（1是 0否）
     */
    @ExcelProperty(value = "是否已审核", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "1=是,0=否")
    private String isAudited;

    /**
     * 排序
     */
    @ExcelProperty(value = "排序")
    private Long sort;

    /**
     * 备注
     */
    @ExcelProperty(value = "备注")
    private String remark;

    /**
     * 状态（0正常 1停用）
     */
    @ExcelProperty(value = "状态", converter = ExcelDictConvert.class)
    @ExcelDictFormat(readConverterExp = "0=正常,1=停用")
    private String status;


}
